package com.simple.framework.security.custom;

import com.simple.business.domain.vo.login.UserLoginSuccessVO;
import org.springframework.security.authentication.AbstractAuthenticationToken;

import java.util.LinkedList;

public class NeedBindPhoneToken extends AbstractAuthenticationToken {
    private final UserLoginSuccessVO loginSuccessVO;
    public NeedBindPhoneToken(UserLoginSuccessVO loginSuccessVO) {
        super(new LinkedList<>());
        this.loginSuccessVO = loginSuccessVO;
    }

    @Override
    public Object getCredentials() {
        return null;
    }

    @Override
    public Object getPrincipal() {
        return loginSuccessVO.getId();
    }

    public UserLoginSuccessVO getLoginSuccessVO() {
        return loginSuccessVO;
    }
}
